import 'package:auto_route/annotations.dart';
import 'package:flutter/material.dart';

import '../../config/Config.dart';

@RoutePage()
class RecordPage extends StatefulWidget {
  const RecordPage({super.key});

  @override
  State<RecordPage> createState() => _RecordPageState();
}

class _RecordPageState extends State<RecordPage> {
  @override
  Widget build(BuildContext context) {
    return Scaffold(
      appBar: AppBar(
        centerTitle: true,
        title: const Text("消费记录"),
        leading: BackButton(
          onPressed: () {
            Navigator.of(context).pop();
          },
        ),
      ),
      body: Container(
        child: ListView(
          children: List.generate(100, (index) {
            return ListTile(
              title: Text(
                "微信VIP",
                style: TextStyle(
                  color: Config.color46,
                  fontWeight: FontWeight.bold,
                ),
              ),
              subtitle: Column(
                mainAxisAlignment: MainAxisAlignment.start,
                crossAxisAlignment: CrossAxisAlignment.start,
                children: [
                  Text(
                    "流水号：2024070108340043512507085",
                    style: TextStyle(
                      fontSize: 12,
                      color: Config.colorB3,
                    ),
                  ),
                  Text(
                    "2024-07-01 08:34:21",
                    style: TextStyle(
                      fontSize: 12,
                      color: Config.colorB3,
                    ),
                  ),
                ],
              ),
              trailing: Column(
                mainAxisAlignment: MainAxisAlignment.center,
                crossAxisAlignment: CrossAxisAlignment.center,
                children: [
                  Text(
                    "68元",
                    style: TextStyle(
                      color: Config.color46,
                      fontWeight: FontWeight.bold,
                    ),
                  ),
                  Text(
                    "会员充值",
                    style: TextStyle(
                      fontSize: 12,
                      color: Config.colorB3,
                    ),
                  ),
                ],
              ),
            );
          }),
        ),
      ),
    );
  }
}
